/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package indexer;

import java.util.ArrayList;

/**
 *
 * @author Claudiu
 */
 class wordEntry {
   public int _word;
   public ArrayList<Integer> documentList;

    public wordEntry(int word, int firstDocument) {
        documentList = new ArrayList<Integer>();
        documentList.add(firstDocument);
        _word = word;
    }
    public void foundInDocument(int document)
    {
        getDocumentList().add(document);
    }
    public boolean check(int word)
    {
        if(_word == word)
        {
            return true;
        }
        else
            return false;
    }

    /**
     * @return the documentList
     */
    public ArrayList<Integer > getDocumentList() {
        return documentList;
    }

    /**
     * @param documentList the documentList to set
     */
    public void setDocumentList(ArrayList<Integer > documentList) {
        this.documentList = documentList;
    }


}
